interface User {
    name: string;
    age: number;
}

class Admin {
    name: string;
    age: number;

    constructor(name: string, age: number) {
        this.name = name;
        this.age = age;
    }
}

function createAdmin(user: User) {
    // ...
}

function getAdmin(): User {
    // ...
}